<LayoutBaseBox>
  <template slot="main">
    <LayoutEditFormBox :loading="load">
      <template slot="main">

        <el-form ref="editForm" :model="form" label-width="200px" label-position="left">

          <LayoutCell>

            <LayoutCellItem title="评论设置">

              <el-form-item label="商品评论">
                <el-switch v-model="form.isOpenComment" style="margin-right:10px" :active-value="1" :inactive-value="0">
                </el-switch>
                <p>商品评论功能已开启，买家可对订单进行评论；商品有评价内容时，将在对应商详中展示</p>
              </el-form-item>

              <el-form-item label="买家交易成功" prop="autoCommentTime" 
                            :rules="[{ required: true,trigger: ['blur', 'change'],validator:function(rule, value, callback){validatorNumber(rule, value, callback)}}]">
                <div class="cell">
                  <div class="l">
                    <el-input-number 
                      controls-position="right" 
                      v-model="form.autoCommentTime" 
                      :min="7" 
                      :max="90" >
                    </el-input-number>
                  </div>
                  <div class="r">
                    天后买家未评论，系统将自动评论 系统默认的时间为7天，手动设置时间最长不超过90天
                  </div>
                </div>
              </el-form-item>

              <el-form-item label="自动评价内容" prop="autoCommentContent" 
                           :rules="{ required: true, message: '请输入,评价内容'}">
                <el-col :span="8">
                  <el-input v-model="form.autoCommentContent" maxlength="50"></el-input>
                </el-col>
              </el-form-item>

              <el-form-item label="新增评论默认状态">
                <el-radio-group v-model="commentStatus">
                  <div class="radioGroup">
                    <div class="radio">
                      <el-radio :label="1">
                        <div class="t1">显示</div>
                      </el-radio>
                    </div>
                    <div class="radio">
                      <el-radio :label="2">
                        <div class="t1">隐藏</div>
                      </el-radio>
                    </div>
                  </div>
                </el-radio-group>
                <p>商家可在【商品】-【商品评论】菜单中，修改已有评论的显示状态</p>
              </el-form-item>

            </LayoutCellItem>

          </LayoutCell>

        </el-form>

      </template>

      <template slot="footer">
        <el-button type="primary" @click="submit()">确定</el-button>
      </template>

    </LayoutEditFormBox>

  </template>
</LayoutBaseBox>